﻿using Shop.RemoteModel.GoodsSpec;
using Shop.RemoteModel.GoodsSpec.Model;
using Shop.Service.Interface;
using WeDonekRpc.Client.Interface;

namespace Shop.Service.RpcEvent
{
    internal class SpecGroupSyncEvent : IRpcApiService
    {
        private readonly ISpecGroupSyncService _Service;

        public SpecGroupSyncEvent (ISpecGroupSyncService service)
        {
            this._Service = service;
        }

        public GoodsSpecGroup[] SyncSpecGroup (SyncSpecGroup obj)
        {
            return this._Service.Sync(obj.GoodsId, obj.CategoryId);
        }
    }
}
